<? $this->load->view('header'); ?>
<div class="backend clearfix">

	<h2>All Site </h2>
	
	<table class="table">

		<thead>
			<tr>
				<th>Name</th>
				<th>Site Url</th>
				<th>Last Update</th>
				<th colspan="2"><span id="tip" class="functions text-center">&nbsp;</span></th>
			</tr>
		</thead>

		<tbody>
		<?php foreach($result as $user): 
		
		?>
	<tr>
			<td><?=$user->name?></td>
			<td><?=$user->site_url?></td>
			<td><?=$user->last_update?></td>

			<?php if($user->user_group !== 'Administrators' OR $this->user->id === '1'): ?>
			<td class="functions2">
				<?=anchor('manage/edit/'.$user->site_id, 'Edit', array('class' => 'icon edit tip', 'title' => 'Edit'))?>	
			
				
				<?=anchor('manage/remove/'.$user->site_id, 'Delete', array('class' => 'icon delete tip', 'title' => 'Delete'))?>
			</td>
			<?php endif ?>
		</tr>
		<?php endforeach ?>
		</tbody>
	</table>
	<br />
	<div id="pagination">
	 <? echo $this->pagination->create_links(); ?>
	 </div>
</div>
<? $this->load->view('footer'); ?>